package com.nlgc365.designpattern.Chapter04_Pattern.Behavior.P08_Snapshot.Issues;

public class StringbuilderUsage {
    public static void main(String[] args) {
        StringBuilder text = new StringBuilder();
        // 追加
        text.append("a");
        text.append("b");
        text.append("c");
        System.out.println(text);
        System.out.println(text.toString());
        // 替换
        text.replace(0, 1, "hello");
        System.out.println(text);

    }
}
